import { request } from 'umi';

// 获取页面内容
export function getPageViews(id: string) {
  return request(`/api/page/${id}/views`, {
    method: 'POST',
  })
}


// 获取文章推荐列表
export function getArticleRecommend() {
  return request('/api/article/recommend')
} 


// 获取文章评论列表
export function getArticleCommentList(id: string, page: number = 1){
  return request(`/api/comment/host/${id}`, {
    params: {
      page,
      pageSize: 12,
    },
  })
}